package com.xjscrm.console.service.customer.circle;

import com.xjscrm.common.annotation.MerId;
import com.xjscrm.console.entity.CircleTaskGroup;
import com.xjscrm.console.mapper.CircleTaskGroupMapper;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author mingyang.chen create in 2024/4/9 上午10:26
 */
@Service
public class CircleTaskGroupService {

    @Resource
    private CircleTaskGroupMapper circleTaskGroupMapper;


    public int deleteByPrimaryKey(@MerId Long merId, Long id) {
        return circleTaskGroupMapper.deleteByPrimaryKey(id);
    }


    public int insertSelective(CircleTaskGroup record) {
        return circleTaskGroupMapper.insertSelective(record);
    }


    public CircleTaskGroup selectByPrimaryKey(Long id) {
        return circleTaskGroupMapper.selectByPrimaryKey(id);
    }


    public int updateByPrimaryKeySelective(CircleTaskGroup record) {
        return circleTaskGroupMapper.updateByPrimaryKeySelective(record);
    }

    //
    public List<CircleTaskGroup> listByStaffId(@MerId Long merId, Long staffId, String name) {
        return circleTaskGroupMapper.selectListByStaffId(merId, staffId, name);
    }

    public Integer selectMaxSort(@MerId Long merId) {
        return circleTaskGroupMapper.selectMaxSort(merId);
    }
}
